{namespace core=TYPO3\CMS\Core\ViewHelpers}

<f:layout name="Default"/>

<f:section name="module-headline">
	<h1><f:translate key="downloadDocumentation">Download Documentation</f:translate></h1>
</f:section>

<f:section name="Content">
	<form class="form-inline">
		<div class="form-group">
			<f:form.textfield name="typo3-documentation-searchfield" placeholder="{f:translate(key:'documentationList.search')}" id="typo3-documentation-searchfield" value="{search}" class="form-control t3js-documentation-searchfield" />
		</div>
	</form>
	<table id="typo3-documentation-download" class="table table-striped table-hover typo3-documentation-list t3js-documentation-list">
		<thead>
		<tr>
			<th><f:translate key="documentation.title" /></th>
			<th class="hidden-xs"><f:translate key="documentation.shortcut" /></th>
			<th class="hidden-xs"><f:translate key="documentation.type" /></th>
			<th><f:translate key="documentation.actions" /></th>
		</tr>
		</thead>
		<tbody>
		<f:for each="{documents}" as="document">
			<tr id="{document.key}" >
				<td class="col-nowrap">
					<span class="typo3-app-icon">
						<span>
							<span>
								<img src="../{document.icon}" title="{document.title}" alt="{document.title}" />
							</span>
						</span>
					</span>
					{document.title}
				</td>
				<td class="hidden-xs">{document.shortcut}</td>
				<td class="hidden-xs">{document.type}</td>
				<td class="col-nowrap">
					<f:link.action action="fetch" arguments="{url:document.url, key:document.key, version:document.version}" class="btn btn-default">
						<span title="{f:translate(key:'documentation.actions.download')}">
							<core:icon identifier="actions-system-extension-download" />
						</span>
					</f:link.action>
				</td>
			</tr>
		</f:for>
		</tbody>
	</table>
</f:section>
